<?php


namespace Modules\Cms\Http\Requests;


use App\Http\Requests\MyRequest;

class ArticleAdRequest  extends MyRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            'title' => ['required','max:255'],
            'single_id' => ['required'],
            'img' => ['required'],
             'description' => ['required'],

        ];
    }

    public function messages(): array
    {
        return [
            'title.required' => '请输入标题名称',
            'title.max' => '标标题称长度错误',
            'single_id.required' => '请选择活动',
            'img.required' => '封面图不能为空',
            'description.required' => '描述不能为空',
        ];
    }
}